package com.leeon.inner;

/**
 *
 * 匿名内部类
 * 1 Runnable 成员匿名内部类
 *
 */
public class AnonymousInnerClass {

    private Runnable runnable = new Runnable() {
        @Override
        public void run() {
            System.out.println("thread name " + Thread.currentThread().getName());
        }
    };

    public static void main(String[] args){
        new Thread(new AnonymousInnerClass().runnable).start();
    }


}
